package com.leon.programPeral.ch2.ext5;

import com.leon.programPeral.ch2.ext3.Ch2Ext3ChangeStringThreeTimeClient;
import com.leon.programPeral.ch2.ext3.WordsUtil;

public class Ch2Ext5ChangeThreePartStringClient
{
	public static void main(String[] args)
	{
		String str = WordsUtil.getRandomStr(10);
		System.out.println(str);
		int i = 2, j = 6;
		String a = str.substring(0, i);
		String b = str.substring(i, j);
		String c = str.substring(j);

		System.out.println(a + " " + b + " " + c);
		a = Ch2Ext3ChangeStringThreeTimeClient.reverse(a);
		b = Ch2Ext3ChangeStringThreeTimeClient.reverse(b);
		c = Ch2Ext3ChangeStringThreeTimeClient.reverse(c);
		String d = Ch2Ext3ChangeStringThreeTimeClient.reverse(a + b + c);
		System.out.println(d);

	}
}
